move geocaching.loc into reference directory.
use ${REFERENCE} to find reference files. not reference. not nothing.
+++ /dev/null
-<?xml version="1.0"?><loc version="1.0" src="EasyGPS"><waypoint><name id="GCEBB"><![CDATA[Mountain Bike Heaven by susy1313]]></name><coord lat="35.9720333333333" lon="-87.1347"/><type>geocache</type><link text="Cache Details">http://www.geocaching.com/seek/cache_details.asp?ID=3771</link></waypoint><waypoint><name id="GC1A37"><![CDATA[The Troll by a182pilot & Family]]></name><coord lat="36.0906833333333" lon="-86.67955"/><type>geocache</type><link text="Cache Details">http://www.geocaching.com/seek/cache_details.asp?ID=6711</link></waypoint><waypoint><name id="GC1C2B"><![CDATA[Dive Bomber by JoGPS & family]]></name><coord lat="35.9962666666667" lon="-86.6201166666667"/><type>geocache</type><link text="Cache Details">http://www.geocaching.com/seek/cache_details.asp?ID=7211</link></waypoint><waypoint><name id="GC25A9"><![CDATA[FOSTER by JoGPS & Family]]></name><coord lat="36.0384833333333" lon="-86.6486166666667"/><type>geocache</type><link text="Cache Details">http://www.geocaching.com/seek/cache_details.asp?ID=9641</link></waypoint><waypoint><name id="GC2723"><![CDATA[Logan Lighthouse by JoGps & Family]]></name><coord lat="36.1121833333333" lon="-86.7417666666667"/><type>geocache</type><link text="Cache Details">http://www.geocaching.com/seek/cache_details.asp?ID=10019</link></waypoint><waypoint><name id="GC2B71"><![CDATA[Ganier Cache by Susy1313]]></name><coord lat="36.0640833333333" lon="-86.7905166666667"/><type>geocache</type><link text="Cache Details">http://www.geocaching.com/seek/cache_details.asp?ID=11121</link></waypoint><waypoint><name id="GC309F"><![CDATA[Shy's Hill by FireFighterEng33]]></name><coord lat="36.0877666666667" lon="-86.8097333333333"/><type>geocache</type><link text="Cache Details">http://www.geocaching.com/seek/cache_details.asp?ID=12447</link></waypoint><waypoint><name id="GC317A"><![CDATA[GittyUp by JoGPS / Warner Parks]]></name><coord lat="36.0575" lon="-86.892"/><type>geocache</type><link text="Cache Details">http://www.geocaching.com/seek/cache_details.asp?ID=12666</link></waypoint><waypoint><name id="GC317D"><![CDATA[Inlighting by JoGPS / Warner Parks]]></name><coord lat="36.0828" lon="-86.8672833333333"/><type>geocache</type><link text="Cache Details">http://www.geocaching.com/seek/cache_details.asp?ID=12669</link></waypoint></loc>
\ No newline at end of file
--- /dev/null
+<?xml version="1.0"?><loc version="1.0" src="EasyGPS"><waypoint><name id="GCEBB"><![CDATA[Mountain Bike Heaven by susy1313]]></name><coord lat="35.9720333333333" lon="-87.1347"/><type>geocache</type><link text="Cache Details">http://www.geocaching.com/seek/cache_details.asp?ID=3771</link></waypoint><waypoint><name id="GC1A37"><![CDATA[The Troll by a182pilot & Family]]></name><coord lat="36.0906833333333" lon="-86.67955"/><type>geocache</type><link text="Cache Details">http://www.geocaching.com/seek/cache_details.asp?ID=6711</link></waypoint><waypoint><name id="GC1C2B"><![CDATA[Dive Bomber by JoGPS & family]]></name><coord lat="35.9962666666667" lon="-86.6201166666667"/><type>geocache</type><link text="Cache Details">http://www.geocaching.com/seek/cache_details.asp?ID=7211</link></waypoint><waypoint><name id="GC25A9"><![CDATA[FOSTER by JoGPS & Family]]></name><coord lat="36.0384833333333" lon="-86.6486166666667"/><type>geocache</type><link text="Cache Details">http://www.geocaching.com/seek/cache_details.asp?ID=9641</link></waypoint><waypoint><name id="GC2723"><![CDATA[Logan Lighthouse by JoGps & Family]]></name><coord lat="36.1121833333333" lon="-86.7417666666667"/><type>geocache</type><link text="Cache Details">http://www.geocaching.com/seek/cache_details.asp?ID=10019</link></waypoint><waypoint><name id="GC2B71"><![CDATA[Ganier Cache by Susy1313]]></name><coord lat="36.0640833333333" lon="-86.7905166666667"/><type>geocache</type><link text="Cache Details">http://www.geocaching.com/seek/cache_details.asp?ID=11121</link></waypoint><waypoint><name id="GC309F"><![CDATA[Shy's Hill by FireFighterEng33]]></name><coord lat="36.0877666666667" lon="-86.8097333333333"/><type>geocache</type><link text="Cache Details">http://www.geocaching.com/seek/cache_details.asp?ID=12447</link></waypoint><waypoint><name id="GC317A"><![CDATA[GittyUp by JoGPS / Warner Parks]]></name><coord lat="36.0575" lon="-86.892"/><type>geocache</type><link text="Cache Details">http://www.geocaching.com/seek/cache_details.asp?ID=12666</link></waypoint><waypoint><name id="GC317D"><![CDATA[Inlighting by JoGPS / Warner Parks]]></name><coord lat="36.0828" lon="-86.8672833333333"/><type>geocache</type><link text="Cache Details">http://www.geocaching.com/seek/cache_details.asp?ID=12669</link></waypoint></loc>
\ No newline at end of file
# it.
#
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -o tabsep -F ${TMPDIR}/tabsep.in
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o tabsep -F ${TMPDIR}/tabsep.in
gpsbabel -i tabsep -f ${TMPDIR}/tabsep.in -o geo -F ${TMPDIR}/tabsep.out
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -o geo -F ${TMPDIR}/geotabsep.out
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o geo -F ${TMPDIR}/geotabsep.out
compare ${TMPDIR}/tabsep.out ${TMPDIR}/geotabsep.out
#
# Now do the same for custom - it has the same issues.
#
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -o custom -F ${TMPDIR}/custom.in
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o custom -F ${TMPDIR}/custom.in
gpsbabel -i custom -f ${TMPDIR}/custom.in -o geo -F ${TMPDIR}/custom.out
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -o geo -F ${TMPDIR}/geocustom.out
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o geo -F ${TMPDIR}/geocustom.out
#
# Write something to the various output-only formats
#
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -o text -F ${TMPDIR}/text.out -o html -F ${TMPDIR}/html.out -o vcard -F ${TMPDIR}/vcard.out #-o palmdoc -F ${TMPDIR}/pd.out
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o text -F ${TMPDIR}/text.out -o html -F ${TMPDIR}/html.out -o vcard -F ${TMPDIR}/vcard.out #-o palmdoc -F ${TMPDIR}/pd.out
# CSV (Comma separated value) data.
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -o csv -F ${TMPDIR}/csv.csv
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o csv -F ${TMPDIR}/csv.csv
gpsbabel -i csv -f ${TMPDIR}/csv.csv -o csv -F ${TMPDIR}/csv2.csv
compare ${TMPDIR}/csv2.csv ${TMPDIR}/csv.csv
# And the alternate command line version.
# as an intermediate format for testing the filter.
#
rm -f ${TMPDIR}/filterdupe.csv1 ${TMPDIR}/filterdupe.csv2
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -o csv -F ${TMPDIR}/filterdupe.csv1
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -f ${REFERENCE}/../geocaching.loc -x duplicate,shortname \
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o csv -F ${TMPDIR}/filterdupe.csv1
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -f ${REFERENCE}/geocaching.loc -x duplicate,shortname \
-o csv -F ${TMPDIR}/filterdupe.csv2
sort_and_compare ${TMPDIR}/filterdupe.csv1 ${TMPDIR}/filterdupe.csv2
rm -f ${TMPDIR}/fugawi*
gpsbabel -i fugawi -f ${REFERENCE}/fugawi.notime.txt -o fugawi -F ${TMPDIR}/fugawi1.txt
compare ${REFERENCE}/fugawi.ref.txt ${TMPDIR}/fugawi1.txt
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -o fugawi -F ${TMPDIR}/fugawi2.txt
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o fugawi -F ${TMPDIR}/fugawi2.txt
compare ${REFERENCE}/fugawi.ref.txt ${TMPDIR}/fugawi2.txt
gpsbabel -i fugawi -f ${TMPDIR}/fugawi2.txt -o fugawi -F ${TMPDIR}/fugawi3.txt
compare ${TMPDIR}/fugawi2.txt ${TMPDIR}/fugawi3.txt
# Geocaching .loc
rm -f ${TMPDIR}/gl.loc
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -o geo -F ${TMPDIR}/gl.loc
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o geo -F ${TMPDIR}/gl.loc
compare ${TMPDIR}/gl.loc ${REFERENCE}
# we have a one off reader in geo, make sure it can read stdin.
rm -f ${TMPDIR}/gl_si.loc
-cat ${REFERENCE}/../geocaching.loc | gpsbabel -i geo -f - -o geo -F ${TMPDIR}/gl_si.loc
+cat ${REFERENCE}/geocaching.loc | gpsbabel -i geo -f - -o geo -F ${TMPDIR}/gl_si.loc
compare ${TMPDIR}/gl_si.loc ${REFERENCE}/gl.loc
# GpsDrive
rm -f ${TMPDIR}/gpsdrive.txt
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -o gpsdrive -F ${TMPDIR}/gpsdrive.txt
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o gpsdrive -F ${TMPDIR}/gpsdrive.txt
compare ${TMPDIR}/gpsdrive.txt ${REFERENCE}
gpsbabel -i gpsdrive -f ${REFERENCE}/gpsdrive.txt -o gpsdrive -F ${TMPDIR}/gpsdrive2.txt
compare ${REFERENCE}/gpsdrive.txt ${TMPDIR}/gpsdrive2.txt
# GPSman
rm -f ${TMPDIR}/gm.gm ${TMPDIR}/gm.gm+
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -o gpsman -F ${TMPDIR}/gm.gm -o gpsutil -F ${TMPDIR}/gu.wpt
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o gpsman -F ${TMPDIR}/gm.gm -o gpsutil -F ${TMPDIR}/gu.wpt
gpsbabel -i gpsman -f ${TMPDIR}/gm.gm -o gpsutil -F ${TMPDIR}/gm.gm+
compare ${TMPDIR}/gm.gm+ ${TMPDIR}/gu.wpt
#
# Franson GPSGate simulation
#
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -o gpssim -F ${TMPDIR}/waypoints.gpssim
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o gpssim -F ${TMPDIR}/waypoints.gpssim
compare ${TMPDIR}/waypoints.gpssim ${REFERENCE}
gpsbabel -i gpx -f ${REFERENCE}/track/tracks.gpx -o gpssim -F ${TMPDIR}/tracks.gpssim
compare ${TMPDIR}/tracks.gpssim ${REFERENCE}/track
# GPSUtil
rm -f ${TMPDIR}/gu.wpt ${TMPDIR}/1.gpx ${TMPDIR}/2.gpx
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -o gpsutil -F ${TMPDIR}/gu.wpt
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o gpsutil -F ${TMPDIR}/gu.wpt
compare ${TMPDIR}/gu.wpt ${REFERENCE}
gpsbabel -i gpsutil -f ${TMPDIR}/gu.wpt -o gpx -F ${TMPDIR}/1.gpx
gpsbabel -i gpsutil -f ${REFERENCE}/gu.wpt -o gpx -F ${TMPDIR}/2.gpx
# GPX
rm -f ${TMPDIR}/gl.gpx ${TMPDIR}/gpx.wpt
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -o gpsman -F ${TMPDIR}/gm.gm -o gpsutil -F ${TMPDIR}/gu.wpt
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -o gpx -F ${TMPDIR}/gl.gpx
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o gpsman -F ${TMPDIR}/gm.gm -o gpsutil -F ${TMPDIR}/gu.wpt
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o gpx -F ${TMPDIR}/gl.gpx
gpsbabel -i gpx -f ${TMPDIR}/gl.gpx -o gpsutil -F ${TMPDIR}/gpx.wpt
compare ${TMPDIR}/gpx.wpt ${TMPDIR}/gu.wpt
# as real world usage shows our writer is more frequently used than our
# reader.
-# gpsbabel -i geo -f geocaching.loc -o unicsv -F ${TMPDIR}/geocaching.txt
+# gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o unicsv -F ${TMPDIR}/geocaching.txt
gpsbabel -i kml -f ${REFERENCE}/kml-points.kml -o unicsv -F ${TMPDIR}/geo~unicsv.txt
compare ${REFERENCE}/kml-points.txt ${TMPDIR}/geo~unicsv.txt
rm -f ${TMPDIR}/lowrance*
# Test ability to read non-Lowrance format and generate USR v2 file
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -o lowranceusr,wversion=2 -F ${TMPDIR}/lowrance1.usr
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o lowranceusr,wversion=2 -F ${TMPDIR}/lowrance1.usr
bincompare ${REFERENCE}/lowrance.usr ${TMPDIR}/lowrance1.usr
# Use the file just created to see if can write back the same data
# Magellan Mapsend
rm -f ${TMPDIR}/mm.mapsend ${TMPDIR}/mm.gps
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -o mapsend -F ${TMPDIR}/mm.mapsend
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o mapsend -F ${TMPDIR}/mm.mapsend
gpsbabel -i mapsend -f ${TMPDIR}/mm.mapsend -o gpsutil -F ${TMPDIR}/mm.gps
compare ${TMPDIR}/mm.gps ${REFERENCE}/gu.wpt
compare ${REFERENCE}/track/amod-cleansed ${TMPDIR}/amod-pure
# Test GPWPL waypoints. Verify we can write first.
-gpsbabel -i geo -f geocaching.loc -o nmea -F ${TMPDIR}/waypoints.nmea
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o nmea -F ${TMPDIR}/waypoints.nmea
compare ${REFERENCE}/waypoints.nmea ${TMPDIR}/waypoints.nmea
# Now read our reference file and prove that our writer will make one to match.
gpsbabel -i nmea -f ${REFERENCE}/waypoints.nmea -o nmea -F ${TMPDIR}/wayout.nmea
# position filter, we can test very similarly to the duplicate filter.
#
rm -f ${TMPDIR}/filterpos.csv1 ${TMPDIR}/filterpos.csv2
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -o csv -F ${TMPDIR}/filterpos.csv1
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -f ${REFERENCE}/../geocaching.loc -x position,distance=5f \
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o csv -F ${TMPDIR}/filterpos.csv1
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -f ${REFERENCE}/geocaching.loc -x position,distance=5f \
-o csv -F ${TMPDIR}/filterpos.csv2
sort_and_compare ${TMPDIR}/filterpos.csv1 ${TMPDIR}/filterpos.csv2
# check a track that loops back with a return leg adjacent to an outgoing leg.
-gpsbabel -i gpx -f reference/track/position_track.gpx -x position,distance=12m -o gpx -F ${TMPDIR}/position_track_filtered.gpx
+gpsbabel -i gpx -f ${REFERENCE}/track/position_track.gpx -x position,distance=12m -o gpx -F ${TMPDIR}/position_track_filtered.gpx
compare ${REFERENCE}/track/position_track_filtered.gpx ${TMPDIR}/position_track_filtered.gpx
# Radius filter
#
rm -f ${TMPDIR}/radius.csv
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc \
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc \
-x radius,lat=35.9720,lon=-87.1347,distance=14.7 \
-o csv -F ${TMPDIR}/radius.csv
compare ${TMPDIR}/radius.csv ${REFERENCE}
# exercise all of the currently-extant filter code.
#
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -x stack,push,copy,nowarn -x stack,push,copy -x stack,push -x stack,pop,replace -x stack,pop,append -x stack,push,copy -x stack,pop,discard -x stack,swap,depth=1 -o arc -F ${TMPDIR}/stackfilt.txt
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -x stack,push,copy,nowarn -x stack,push,copy -x stack,push -x stack,pop,replace -x stack,pop,append -x stack,push,copy -x stack,pop,discard -x stack,swap,depth=1 -o arc -F ${TMPDIR}/stackfilt.txt
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -x transform,rte=wpt,del -x stack,push,copy,nowarn -x stack,push,copy -x stack,push -x stack,pop,replace -x stack,pop,append -x stack,push,copy -x stack,pop,discard -x stack,swap,depth=1 -o arc -F ${TMPDIR}/stackfilt.txt
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -x transform,rte=wpt,del -x stack,push,copy,nowarn -x stack,push,copy -x stack,push -x stack,pop,replace -x stack,pop,append -x stack,push,copy -x stack,pop,discard -x stack,swap,depth=1 -o arc -F ${TMPDIR}/stackfilt.txt
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -x transform,trk=wpt,del -x stack,push,copy,nowarn -x stack,push,copy -x stack,push -x stack,pop,replace -x stack,pop,append -x stack,push,copy -x stack,pop,discard -x stack,swap,depth=1 -o arc -F ${TMPDIR}/stackfilt.txt
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -x transform,trk=wpt,del -x stack,push,copy,nowarn -x stack,push,copy -x stack,push -x stack,pop,replace -x stack,pop,append -x stack,push,copy -x stack,pop,discard -x stack,swap,depth=1 -o arc -F ${TMPDIR}/stackfilt.txt
# so we simply test we can write it, and then read it and write it and
# get an identical file back.
rm -f ${TMPDIR}/tiger
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -o tiger -F ${TMPDIR}/tiger
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o tiger -F ${TMPDIR}/tiger
gpsbabel -i tiger -f ${TMPDIR}/tiger -o tiger -F ${TMPDIR}/tiger2
compare ${TMPDIR}/tiger ${TMPDIR}/tiger2
# against a format that rounds higher than we care to compare
# for binary data.
rm -f ${TMPDIR}/topo.mxf ${TMPDIR}/tpg.mxf ${TMPDIR}/geo.tpg
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -o tpg -F ${TMPDIR}/geo.tpg
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o tpg -F ${TMPDIR}/geo.tpg
gpsbabel -i tpg -f ${TMPDIR}/geo.tpg -o mxf -F ${TMPDIR}/tpg.mxf
gpsbabel -i tpg -f ${REFERENCE}/tpg.tpg -o mxf -F ${TMPDIR}/topo.mxf
compare ${TMPDIR}/tpg.mxf ${TMPDIR}/topo.mxf
compare ${REFERENCE}/track/trackfilter_discard_out.gpx ${TMPDIR}/discard.gpx
# This file has ONLY names starting with GC; verify we toss all.
-gpsbabel -i geo -f geocaching.loc -x discard,matchname=GC* -o csv -F ${TMPDIR}/discardgc.geo
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -x discard,matchname=GC* -o csv -F ${TMPDIR}/discardgc.geo
compare ${TMPDIR}/discardgc.geo /dev/null
# Throw out all caches from Joe
-gpsbabel -i geo -f geocaching.loc -x discard,matchdesc=JoGPS -o csv -F ${TMPDIR}/discardjoe.csv
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -x discard,matchdesc=JoGPS -o csv -F ${TMPDIR}/discardjoe.csv
nlines=$(wc -l ${TMPDIR}/discardjoe.csv | awk '{print $1}')
if [ $nlines -ne 4 ];
then
echo "IFIELD LAT_DIRDECIMAL,,%c%lf" >> ${TMPDIR}/testo.style
echo "IFIELD LON_DECIMALDIR,,%lf%c" >> ${TMPDIR}/testo.style
rm -f ${TMPDIR}/xcsv.geo ${TMPDIR}/xcsv.xcsv
-gpsbabel -i geo -f ${REFERENCE}/../geocaching.loc -o xcsv,style=${TMPDIR}/testo.style -F ${TMPDIR}/xcsv.geo
+gpsbabel -i geo -f ${REFERENCE}/geocaching.loc -o xcsv,style=${TMPDIR}/testo.style -F ${TMPDIR}/xcsv.geo
gpsbabel -i xcsv,style=${TMPDIR}/testo.style -f ${TMPDIR}/xcsv.geo -o xcsv,style=${TMPDIR}/testo.style -F ${TMPDIR}/xcsv.xcsv
compare ${TMPDIR}/xcsv.geo ${TMPDIR}/xcsv.xcsv